package com.zxl.live.screen.ui.helper;

import android.content.Context;

import com.zxl.live.screen.screen.constant.LockerEnv;
import com.zxl.live.tools.common.ApplicationHelper;
import com.zxl.live.tools.tools.AppUtils;

/**
 * Created by Administrator on 2017/5/8.
 */

public class MarketUrlHelper {

    private static MarketUrlHelper sInstance;

    private MarketUrlHelper() {
    }

    public static MarketUrlHelper getInstance() {
        if (null == sInstance) {
            sInstance = new MarketUrlHelper();
        }
        return sInstance;
    }

    public boolean haveMarket() {
        return AppUtils.isAppExist(ApplicationHelper.getContext(), LockerEnv.Package.MARKET);
    }

    public void gotoMarket(Context mContext, String packageName) {
        AppUtils.gotoMarket(mContext, LockerEnv.Package.MARKET, LockerEnv.Market.APP_DETAIL + packageName);
    }

}
